<h1><%= t('admin.users.index.title') %></h1>

<table class='list'>
  <thead>
    <tr>
      <th><%= t('admin.users.show.first_name') %></th>
      <th><%= t('admin.users.show.last_name') %></th>
      <th><%= t('admin.users.show.email') %></th>
      <th></th>
    </tr>
  </thead>
  <tbody>
    <% @users.each do |user| %>
      <tr>
        <td><%= user.first_name %></td>
        <td><%= user.last_name %></td>
        <td><%= truncate(user.email, length: 25) %></td>
        <td><i class='icon-pencil'></i><%= link_to t('admin.users.index.edit_link'), edit_admin_user_path(user) %><i class='icon-trash'></i><%= link_to t('admin.users.index.delete_link'), admin_user_path(user), confirm: t('admin.actions.confirm'), :method => :delete, class: 'danger' if can? :update, user %></td>
      </tr>
    <% end %>
  </tbody>
</table>

<%= will_paginate @users %>
